home *** CD-ROM | disk | FTP | other *** search
/ Futurshow - Un Taglio Al Passato / Futurshow - Un Taglio Al Passato.iso / pc / common.cst / 00031_Script_31 < prev    next >
Text File  |  1998-03-11  |  4KB  |  144 lines

  1. on startMovie
  2.   global lout
  3.   
  4.   set lout=FALSE
  5.   set the cursor of sprite 85 to [18,19]
  6.   set the cursor of sprite 86 to [18,19]
  7. end
  8.  
  9. on closeAllWindow
  10.   put count(the windowList) into temp
  11.   
  12.   repeat with i = 1 to temp
  13.     close getAt(the windowList,1)
  14.   end repeat 
  15. end
  16.  
  17. on openFloatWindow theFile,theName
  18.   cursor 4
  19.   
  20.   put the rect of the stage into wRect
  21.   put getAt(wRect,1)+40 into dx
  22.   put getAt(wRect,2)+40 into dy
  23.   set the fileName of window theName to theFile 
  24.   put the rect of window theName into wRect
  25.   set nRect=rect(0+dx,0+dy,(getAt(wRect,3)-getAt(wRect,1))+dx,(getAt(wRect,4)-getAt(wRect,2))+dy)
  26.   set the rect of window theName to nRect
  27.   set the windowType of window theName to 49
  28.   open window theName
  29.   
  30.   cursor 0
  31. end
  32.  
  33. on crunchLink theField
  34.   set mChar=mouseChar()
  35.   
  36.   if mChar>0 and getCharStyle(mChar,theField)="underline" then
  37.     set selCol=the foreColor of member "red"
  38.     set stdCol=the foreColor of char mChar of member theField
  39.     
  40.     set sChar=mChar-1
  41.     set eChar=mChar+1
  42.     repeat while(getCharStyle(sChar,theField)="underline" and sChar>0)
  43.       set sChar=sChar-1
  44.     end repeat
  45.     set sChar=sChar+1
  46.     
  47.     repeat while(getCharStyle(eChar,theField)="underline" and eChar<=length(field theField))
  48.       set eChar=eChar+1
  49.     end repeat
  50.     set eChar=eChar-1
  51.     
  52.     set the foreColor of Char sChar to eChar of member theField to selCol
  53.     set flag = TRUE
  54.     repeat while stillDown()
  55.       if mouseChar()>=sChar and  mouseChar()<=eChar then
  56.         if not flag then 
  57.           set the foreColor of char sChar to eChar of member theField to selCol
  58.           set flag = TRUE
  59.         end if
  60.       else
  61.         if flag then 
  62.           set the foreColor of char sChar to eChar of member theField to stdCol
  63.           set flag = FALSE
  64.         end if
  65.       end if
  66.     end repeat
  67.     set the foreColor of char sChar to eChar of member theField to stdCol
  68.     
  69.     if flag then 
  70.       put char sChar to eChar of field theField into temp
  71.       put "http://"&temp into temp
  72.       goToNetPage(temp)
  73.     end if
  74.   end if
  75. end
  76.  
  77. on getCharStyle xx,theField
  78.   return the fontStyle of char xx of member theField
  79. end
  80.  
  81. on trackScroll theSprite
  82.   puppetSprite clickOn(),TRUE
  83.   
  84.   set theMember=the member of sprite theSprite
  85.   set SLine = locVtoLinePos(theMember,the scrollTop of theMember)
  86.   
  87.   repeat while stillDown()
  88.     put mouseV() into CurrMouse
  89.     put constrainV(clickOn()-1,CurrMouse) into temp
  90.     set the locV of sprite clickOn() to temp 
  91.     
  92.     put the height of sprite (clickOn()-1) into S
  93.     put the locV of sprite clickOn() - the top of sprite (clickOn()-1) into temp
  94.     put ((the lineCount of theMember) - 1) * temp / S +1 into SLine
  95.     set the scrollTop of theMember to linePosTolocV(theMember,SLine)
  96.     updateStage
  97.   end repeat
  98. end 
  99.  
  100.  
  101. on openL
  102.   global lout
  103.   
  104.   set sN=80
  105.   if not lout then
  106.     set lout=TRUE
  107.     repeat with i=1 to 13
  108.       puppetSprite sN,TRUE
  109.       puppetSprite sN+1,TRUE
  110.       puppetSprite sN+2,TRUE
  111.       puppetSprite sN+3,TRUE
  112.       puppetSprite sN+4,TRUE
  113.       set the locH of sprite sN to (the locH of sprite sN)-10
  114.       set the locH of sprite (sN+1) to (the locH of sprite (sN+1))-10
  115.       set the locH of sprite (sN+2) to (the locH of sprite (sN+2))-10
  116.       set the locH of sprite (sN+3) to (the locH of sprite (sN+3))-10
  117.       set the locH of sprite (sN+4) to (the locH of sprite (sN+4))-10
  118.       updateStage
  119.     end repeat
  120.   end if
  121. end
  122.  
  123. on closeL
  124.   global lout
  125.   
  126.   set sN=80
  127.   if lout then
  128.     set lout=FALSE
  129.     repeat with i=1 to 13
  130.       set the locH of sprite sN to (the locH of sprite sN)+10
  131.       set the locH of sprite (sN+1) to (the locH of sprite (sN+1))+10
  132.       set the locH of sprite (sN+2) to (the locH of sprite (sN+2))+10
  133.       set the locH of sprite (sN+3) to (the locH of sprite (sN+3))+10
  134.       set the locH of sprite (sN+4) to (the locH of sprite (sN+4))+10
  135.       updateStage
  136.       puppetSprite sN,FALSE
  137.       puppetSprite sN+1,FALSE
  138.       puppetSprite sN+2,FALSE
  139.       puppetSprite sN+3,FALSE
  140.       puppetSprite sN+4,FALSE
  141.     end repeat
  142.   end if
  143. end
  144.